#pragma once

#include <cufft.h>
#include "ftlibcuda.h"

enum class CUDAFTPLANHANDLETYPE : uint16_t
{
	_2dRealToComplexPackedFftw,
	_2dRealToComplex,
	_2dComplexToComplex,
	_2dHermetianToReal
};

struct CUDAFTPLANHANDLEInternal
{
	cufftHandle	cuFftplan;
	intptr_t ptrType1;
	intptr_t ptrType2;
	intptr_t ptrType3;
	float	normalization;
	CUDAFTPLANHANDLETYPE planType;

	inline void DummyStaticSizeCheck()
	{
		static_assert(sizeof(CUDAFTPLANHANDLEInternal) == sizeof(CUDAFTPLANHANDLE), "Sizes of CUDAFTPLANHANDLEInternal and CUDAFTPLANHANDLE must be the same");
	}
};

union CUDAFTPLANHANDLEDual
{
	CUDAFTPLANHANDLEInternal	internal;
	CUDAFTPLANHANDLE			external;
};
